package com.ftg.learn.chapter08.combination.c;

import com.ftg.learn.chapter08.combination.A;
import com.ftg.learn.chapter08.combination.B;

/**
 * @author kangjx
 * @createTime 2023/1/6
 */
public class C {

    A a1;
    B b1 = new B();

    public A getA1() {
        return a1;
    }

    public void setA1(A a1) {
        this.a1 = a1;
    }

    public void test1(){
        System.out.println(getA1().publicInt);
        System.out.println(b1.publicInt);

        System.out.println(a1.publicMethod());
    }

    //封装  继承 多态 抽象

}
